<?php

header('Content-Type:text/xml');

$id = (float)$_GET['id'];
$walk = '-1';
if($id > 0)
{
  $lines = file('data.xml');
  foreach ($lines as $line_num => $line) 
  {
    if(substr_count($line, ' id="'.$id.'"') > 0)
    {
      $walk = $line;
      break;
    }
  }
}

echo <<<XML
<walks>$walk</walks>
XML;
?>